import { Column, Entity, PrimaryGeneratedColumn, BaseEntity, CreateDateColumn, UpdateDateColumn, ManyToOne, ManyToMany } from 'typeorm';
import { Role } from './role.entity';
import { RoleAdmin } from 'src/admin/entities/roleAdmin.entity';
@Entity('role_auth')
export class Auth extends BaseEntity {
    @PrimaryGeneratedColumn()
    id: number;
    @Column('int')
    roleId: number;
    @Column('int')
    menuId: number;
    @Column()
    actionIds: string;
    @Column('tinyint')
    status: number;
    @ManyToOne(() => Role, role => role.auth)
    role: Role
    @ManyToMany(() => RoleAdmin, roleAdmin => roleAdmin.auth)
    roleAdmin: RoleAdmin[]
}
